package cn.mw.cmdb.entity;

import cn.mw.cmdb.param.AssetsDiscoverRuleParam;
import cn.mw.cmdb.param.MwDiscoveryExecutorTypeEnum;
import cn.mw.cmdb.param.MwScanTypeDiscoveryEnum;
import cn.mw.components.mongodb.anno.CMDBProperty;
import cn.mw.microMonitorCommon.api.scan.IPRangeParam;
import cn.mw.microMonitorCommon.api.scan.SubnetParam;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import lombok.Data;

import java.util.List;

import static cn.mw.cmdb.param.MwScanTypeDiscoveryEnum.manualScan;

@Data
public class AssetsDiscoverInfoVo extends DataAuth {
    private String id;
    @Schema(description = "规则名")
    private String ruleName;
    @Schema(description = "时长")
    private String timeLength;
    @Schema(description = "状态")
    private String status;
    @Schema(description = "ip清单")
    private String ips;
    @Schema(description = "是否ipv6")
    private Boolean ipv6checked;
    @Schema(description = "ip范围")
    private List<IPRangeParam> ipRange;
    @Schema(description = "ip地址段")
    private List<SubnetParam> ipSubnet;
    @Schema(description = "ip类型")
    private List<String> ipTypeList;
    @Schema(description = "轮训引擎ID")
    private String engineId;
    @Schema(description = "扫描进度")
    private Integer progress;
    @Schema(description = "开始时间")
    private Long scanStartDate;
    @Schema(description = "结束时间")
    private Long scanEndDate;
    @Schema(description = "扫描检查规则")
    private List<AssetsDiscoverRuleParam> scanRules;
    @Schema(description = "责任人")
    private List<Integer> principal;
    @Schema(description = "执行人")
    private String executor;

    @Schema(description = "扫描资产总数")
    private int totalNum;

    @Schema(description = "扫描资产成功总数")
    private int successNum;

    @Schema(description = "扫描资产失败总数")
    private int failNum;

    @Schema(description = "扫描类型")
    private MwScanTypeDiscoveryEnum scanType = manualScan;

    @Schema(description = "关联时间计划")
    private String timePlanId;
    // 执行模式
    @Schema(description = "执行模式")
    private MwDiscoveryExecutorTypeEnum executorType;
    // 规则
    @Schema(description = "规则id")
    private String customRuleId;

}
